﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Rappelz.GameServer
{
    class AuctionManager
    {
        private static AuctionManager m_instance = null;

        internal static AuctionManager Instance
        {
            get 
            {
                if (m_instance == null)
                    m_instance = new AuctionManager();
                return AuctionManager.m_instance; 
            }
        }


// UserDefinedType: AuctionManager
// BaseClass      :   ArSchedulerObject, offset = 0x0
// VTable         :     , Type:  *
// Enum           :     AR_OBJECT_PRIORITY, Type: int
// Function       :     public void ArSchedulerObject(const struct ArSchedulerObject &)
// Function       :     public void ArSchedulerObject::ArSchedulerObject()
// Function       :     public unsigned int ArSchedulerObject::GetHandle()
// Function       :     public void ArSchedulerObject::onProcess(int)
// Function       :     public bool IsEnable()
// Function       :     public void Disable()
// Function       :     public bool IsDeleteRequested()
// Function       :     public volatile enum ArSchedulerObject::AR_OBJECT_PRIORITY GetPriority()
// Function       :     public volatile unsigned int GetPriorityQueueIndex()
// Function       :     public volatile int GetPendingPriority()
// Function       :     public volatile int GetFinalPriority()
// Function       :     public void EnterSpinLock()
// Function       :     public void LeaveSpinLock()
// Function       :     public volatile __int64 GetLastProcTime()
// Function       :     public volatile unsigned int GetLastProcTick()
// Data           :     this+0x8, Member, Type: volatile bool, bIsDeleteRequested
// Data           :     this+0x10, Member, Type: volatile __int64, last_proc_time
// Data           :     this+0x18, Member, Type: volatile unsigned int, last_proc_tick
// Data           :     this+0x1C, Member, Type: volatile enum ArSchedulerObject::AR_OBJECT_PRIORITY, pending_priority
// Data           :     this+0x20, Member, Type: volatile int, pending_thread_index
// Data           :     this+0x24, Member, Type: volatile unsigned int, pending_priority_queue_index
// Data           :     this+0x28, Member, Type: volatile enum ArSchedulerObject::AR_OBJECT_PRIORITY, priority
// Data           :     this+0x2C, Member, Type: volatile int, thread_index
// Data           :     this+0x30, Member, Type: volatile unsigned int, priority_queue_index
// Data           :     this+0x34, Member, Type: volatile int, lock
// Function       :     protected bool ArSchedulerObject::ProcDelete()
// Function       :     protected bool ArSchedulerObject::IsDeleteable()
// Function       :     protected void ArSchedulerObject::~ArSchedulerObject()
// Data           :     this+0x38, Member, Type: volatile bool, m_bIsEnable
// Function       :     public struct ArSchedulerObject & operator=(const struct ArSchedulerObject &)
// Function       :     public void __local_vftable_ctor_closure()
// Function       :     protected void * __vecDelDtor(unsigned int)
// 
// Typedef        :   , Type: class std::vector<AuctionInfo *,std::allocator<AuctionInfo *> >
// Typedef        :   , Type: class std::_Vector_iterator<AuctionInfo *,std::allocator<AuctionInfo *> >
// Typedef        :   , Type: class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >
// UserDefinedType:   AuctionListIterator
// BaseClass      :     std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Const_iterator<1>, offset = 0x0
// 
// UserDefinedType:     _Myt_iter
// UserDefinedType:     _Mybase_iter
// Typedef        :     , Type: struct std::bidirectional_iterator_tag
// Typedef        :     , Type: class AuctionInfo *
// Typedef        :     , Type: int
// Typedef        :     , Type: class AuctionInfo * *
// Typedef        :     , Type: class AuctionInfo * &
// Function       :     public void _Iterator<1>(struct std::_List_nod<AuctionInfo *,std::allocator<AuctionInfo *> >::_Node *, const class std::list<AuctionInfo *,std::allocator<AuctionInfo *> > *)
// Function       :     public void _Iterator<1>()
// UserDefinedType:     _Checked_iterator_base_type
// Function       :     public class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Iterator<0> _Checked_iterator_base()
// Function       :     public void _Checked_iterator_assign_from_base(class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Iterator<0>)
// Function       :     public class AuctionInfo * & operator*()
// Function       :     public class AuctionInfo * * operator->()
// Function       :     public class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Iterator<1> operator++(int)
// Function       :     public class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Iterator<1> & operator++()
// Function       :     public class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Iterator<1> operator--(int)
// Function       :     public class std::list<AuctionInfo *,std::allocator<AuctionInfo *> >::_Iterator<1> & operator--()
// Typedef        :   , Type: class std::vector<ItemKeepingInfo *,std::allocator<ItemKeepingInfo *> >
// Typedef        :   , Type: class std::_Vector_iterator<ItemKeepingInfo *,std::allocator<ItemKeepingInfo *> >
// Typedef        :   , Type: class std::vector<AutoAuctionInfo *,std::allocator<AutoAuctionInfo *> >
// Typedef        :   , Type: class std::_Vector_iterator<AutoAuctionInfo *,std::allocator<AutoAuctionInfo *> >
// Function       :   public static struct AuctionManager & AuctionManager::Instance()
// Function       :   public void AuctionManager::~AuctionManager()
        public bool RegisterAuctionCategory(int category_id, int sub_category_id, int item_group, int item_class)
        {
            return true;
        }

        public bool FinalizeAuctionCategory()
        {
            return true;
        }

        // Function       :   public unsigned int GetAuctionCategoryCount(const bool)

        public uint GetAuctionItemCategoryCount()
        {
            return 0;
        }
// Function       :   public bool AuctionManager::AddAuctionInfoByLoading(class AuctionInfo *)
// Function       :   public bool AuctionManager::AddItemKeepingInfoByLoading(class ItemKeepingInfo *)
// Function       :   public bool AuctionManager::Init()
// Function       :   public bool DeInit()
// Function       :   public unsigned short AuctionManager::SearchAndSendAuctionList(const struct StructPlayer *, const int, const int, const char *, const int)
// Function       :   public unsigned short AuctionManager::SendRegisteredAuctionList(const struct StructPlayer *, const int)
// Function       :   public unsigned short AuctionManager::SendBiddedAuctionList(const struct StructPlayer *, const int)
// Function       :   public unsigned short AuctionManager::RegisterItemToSell(const char *, unsigned int, const bool, const __int64, const struct StructGold &, const struct StructGold &, int *)
// Function       :   public unsigned short AuctionManager::RegisterItemToSell(struct StructPlayer *, unsigned int, const __int64 &, const __int64, const struct StructGold &, const struct StructGold &, int *)
// Function       :   public unsigned short AuctionManager::BidForAuction(struct StructPlayer *, const int, const struct StructGold &, int &)
// Function       :   public unsigned short AuctionManager::InstantPurchase(struct StructPlayer *, const int, int &)
// Function       :   public unsigned short AuctionManager::CancelAuction(const int &, class std::vector<int,std::allocator<int> > &, const struct StructPlayer *)
// Function       :   public unsigned short AuctionManager::CancelAuction(const struct StructPlayer *, const int, int &)
// Function       :   public unsigned short AuctionManager::SendKeepingItemList(const struct StructPlayer *, const int)
// Function       :   public unsigned short AuctionManager::TakeKeepedItem(struct StructPlayer *, const int)
// Function       :   public void AuctionManager::ClearAutoAuctionInfo()
// Function       :   public bool AuctionManager::AddAutoAuctionInfo(const int, const char *, const int, const __int64 &, const struct StructGold &, const struct StructGold &, const __int64, const __int64, const bool, const bool, const __int64)
// Function       :   public unsigned int GetAutoAuctionResouceCount()
// Function       :   public void AuctionManager::ClearAutoAuctionRegistrationInfo()
// Function       :   public bool AuctionManager::SetLastAutoRegisteredTime(const int, const __int64)
// Function       :   public bool AuctionManager::IsRegisteredAutoAuction(const int)
// Function       :   public void AuctionManager::OnChangeCharacterName(const int, const char *)
// Function       :   public void AuctionManager::onProcess(int)
// Function       :   public void AuctionManager::Push(struct GameDBManager::DBProc *)
// Function       :   public void AuctionManager::onEndQuery()
// Function       :   protected unsigned short AuctionManager::cancelAuction(class AuctionInfo *, int &, const char *, const char *, const int &)
// Function       :   public void AuctionManager(const struct AuctionManager &)
// Function       :   private void AuctionManager::AuctionManager()
// Function       :   private int AuctionManager::getCategoryIndex(const enum ItemBase::ITEM_GROUP, const enum ItemBase::ItemClass)
// Function       :   private unsigned short AuctionManager::addAuctionInfoToIndex(class AuctionInfo *, const bool)
// Function       :   private unsigned short AuctionManager::removeAuctionInfoFromIndex(const int, const bool)
// Function       :   private unsigned short AuctionManager::addItemKeepingInfoToIndex(class ItemKeepingInfo *)
// Function       :   private unsigned short AuctionManager::removeItemKeepingInfoFromIndex(const int, const int, const bool)
// Data           :   this+0x40, Member, Type: class XCriticalSection, m_AuctionLock
// UserDefinedType:     XCriticalSection
// 
// Data           :   this+0x80, Member, Type: class std::vector<AuctionCategoryInfo,std::allocator<AuctionCategoryInfo> >, m_vAuctionCategory
// UserDefinedType:     std::vector<AuctionCategoryInfo,std::allocator<AuctionCategoryInfo> >
// 
// Data           :   this+0x90, Member, Type: int, m_nMaxCategoryIndex
// Data           :   this+0x94, Member, Type: class std::vector<std::list<AuctionInfo *,std::allocator<AuctionInfo *> > *,std::allocator<std::list<AuctionInfo *,std::allocator<AuctionInfo *> > *> >, m_vplAuctionListByCategory
// UserDefinedType:     std::vector<std::list<AuctionInfo *,std::allocator<AuctionInfo *> > *,std::allocator<std::list<AuctionInfo *,std::allocator<AuctionInfo *> > *> >
// 
// Data           :   this+0xA4, Member, Type: class KHash<AuctionInfo *,khash_def::hashPr_mod_basic<int> >, m_hsAuctionListByAuctionID
// UserDefinedType:     KHash<AuctionInfo *,khash_def::hashPr_mod_basic<int> >
// 
// Data           :   this+0xC0, Member, Type: class KHash<std::vector<AuctionInfo *,std::allocator<AuctionInfo *> > *,khash_def::hashPr_mod_basic<int> >, m_hsAuctionListBySellerUID
// UserDefinedType:     KHash<std::vector<AuctionInfo *,std::allocator<AuctionInfo *> > *,khash_def::hashPr_mod_basic<int> >
// 
// Data           :   this+0xDC, Member, Type: class KHash<std::vector<AuctionInfo *,std::allocator<AuctionInfo *> > *,khash_def::hashPr_mod_basic<int> >, m_hsBiddedAuctionList
// UserDefinedType:     KHash<std::vector<AuctionInfo *,std::allocator<AuctionInfo *> > *,khash_def::hashPr_mod_basic<int> >
// 
// Data           :   this+0xF8, Member, Type: class XCriticalSection, m_ItemKeepingLock
// UserDefinedType:     XCriticalSection
// 
// Data           :   this+0x138, Member, Type: class std::vector<ItemKeepingInfo *,std::allocator<ItemKeepingInfo *> >, m_vItemKeepingList
// UserDefinedType:     std::vector<ItemKeepingInfo *,std::allocator<ItemKeepingInfo *> >
// 
// Data           :   this+0x148, Member, Type: class KHash<std::vector<ItemKeepingInfo *,std::allocator<ItemKeepingInfo *> > *,khash_def::hashPr_mod_basic<int> >, m_hsItemKeepingList
// UserDefinedType:     KHash<std::vector<ItemKeepingInfo *,std::allocator<ItemKeepingInfo *> > *,khash_def::hashPr_mod_basic<int> >
// 
// Data           :   this+0x164, Member, Type: class XCriticalSection, m_AutoAuctionLock
// UserDefinedType:     XCriticalSection
// 
// Data           :   this+0x1A4, Member, Type: class std::vector<AutoAuctionInfo *,std::allocator<AutoAuctionInfo *> >, m_vAutoAuction
// UserDefinedType:     std::vector<AutoAuctionInfo *,std::allocator<AutoAuctionInfo *> >
// 
// Data           :   this+0x1B4, Member, Type: class XCriticalSection, m_QueryLock
// UserDefinedType:     XCriticalSection
// 
// Data           :   this+0x1F4, Member, Type: class std::list<GameDBManager::DBProc *,std::allocator<GameDBManager::DBProc *> >, m_lQueryList
// UserDefinedType:     std::list<GameDBManager::DBProc *,std::allocator<GameDBManager::DBProc *> >
// 
// Function       :   public struct AuctionManager & operator=(const struct AuctionManager &)
// Function       :   public void __local_vftable_ctor_closure()
// Function       :   public void * __vecDelDtor(unsigned int)

    }
}
